<%@ page language="java" import="java.util.*" pageEncoding="UTF-8" contentType="text/html; charset=utf-8" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<html>
<jsp:include page="../head.jsp"></jsp:include>
<body>
<form id='fmTbProductUnit'  action="TbProductUnitServlet?method=${sessionScope.tbProductUnit==null?'add':'edit'}" method='post'>
<input type='hidden' name='productUnitId' id='productUnitId' value='${sessionScope.tbProductUnit.productUnitId }' />
<table>
<tr><td colspan='2'>&nbsp;</td></tr>
<tr>
    <td>单位</td>
    <td><input type='text' name='productUnitName' id='productUnitName' value='${sessionScope.tbProductUnit.productUnitName }' /></td>
</tr>
<tr>
    <td>单位符号</td>
    <td><input type='text' name='productUnitSymbol' id='productUnitSymbol' value='${sessionScope.tbProductUnit.productUnitSymbol }' /></td>
</tr>
<tr>
    <td>换算公式</td>
    <td><input type='text' name='productUnitFormula' id='productUnitFormula' value='${sessionScope.tbProductUnit.productUnitFormula }' /></td>
</tr>
<tr>
    <td>上级单位</td>
    <td>
    <select name='parentProductUnitId' id='parentProductUnitId' >
		<option value="0">无</option>
	<c:forEach items="${sessionScope.tbProductUnitList==null?'':sessionScope.tbProductUnitList}" var="tbProductUnit" varStatus="status">
		<option value="${tbProductUnit.productUnitId }" ${sessionScope.tbProductUnit.parentProductUnitId == tbProductUnit.productUnitId?'selected':''}>${tbProductUnit.productUnitName}</option>
	</c:forEach>
	</select>
    </td>
</tr>
<tr>
    <td>备注</td>
    <td><input type='text' name='productUnitMemo' id='productUnitMemo' value='${sessionScope.tbProductUnit.productUnitMemo }' /></td>
</tr>
<tr>
    <td colspan='2' align='center' ><input type="submit" name="btsubmit" id="btsubmit" value="${sessionScope.tbProductUnit==null?'添加':'修改'}" /><input type='reset' value='重置' /><input type='button' value='返回' onclick='history.go(-1);' /></td>
</tr></table>

</form><jsp:include page="../foot.jsp"></jsp:include>
</body></html>